TempFiles

object TempFiles : Base<TempFiles>

Utility to work with temporary files.

Functions

Link copied to clipboard
fun clearTempFilesFolder(context: Context)

Delete all files created with this utility (the files in the temporary folder), it is recommended to call in the start of the app or where you need to clean the contents of the folder. The function runs asynchronously so as not to affect the app flow and can be called from anywhere.

Link copied to clipboard
fun makeTempDir(context: Context)

Create the directory for temporary files (if it does not already exist), invoke whenever you are going to work with the temporary files directory.

Properties

Link copied to clipboard
var firebaseAnalyticsEnabled: Boolean

Determines if the event log in Firebase Analytics is enabled for the class instance, for the event log, the static property of the companion object firebaseAnalyticsInstance must also be assigned, if that property is null, no events will be logged, since what is required.

Link copied to clipboard
const val TEMP_FILES_DIR: String

Directory to store temporary files, the parent is context.filesDir